package org.jsystemtest.tests_proj;

import jsystem.extensions.analyzers.text.FindText;
import jsystem.framework.system.SystemObjectImpl;
import junit.framework.SystemTestCase4;

import org.junit.Test;

public class FindTextExample extends SystemTestCase4 {

	private MySystemObject imdbSystemObject = new MySystemObject();

	@Test
	public void anotherFindText(){
		analyzer.setTestAgainstObject("Itai Agmon");
		analyzer.analyze(new FindText("Itai"));
	}

	@Test
	public void findTextExample() {
		// Perform operation
		imdbSystemObject.retrieveMovieNames("Star Wars");

		// Analyze result
		FindText findTextAnalyzer = new FindText("A New Hope12");
		boolean status = imdbSystemObject.isAnalyzeSuccess(findTextAnalyzer);
		report.report(status + "");
		findTextAnalyzer.getTitle();
	}

	class MySystemObject extends SystemObjectImpl {

		public void retrieveMovieNames(String movie) {
			setTestAgainstObject("The Phantom Menace Attack of the Clones The Clone 		Wars"
					+ "Revenge of the Sith A New Hope The Empire Strikes Back Return of the 		Jedi");
		}
	}

}